local myApp = {
  name: std.extVar("name"),
  image: std.extVar("image"),
};

{
  apiVersion: 'apps/v1',
  kind: 'Deployment',
  metadata: {
    name: myApp.name,
    labels: { app: myApp.name },
  },
  spec: {
    selector: { matchLabels: $.metadata.labels },
    template: {
      metadata: { labels: $.metadata.labels },
      spec: {
        containers: [{
          name: myApp.name,
          image: myApp.image,
        }],
      },
    },
  },
}